//
// http://www.opengldistilled.com
//
// This code was written by Paul Martz (pmartz@opengldistilled.com)
//
// This code comes with absolutely no warranty.
//
// You may freely use, distribute, modify, and publish this source
// code, provided that this comment block remains intact in all
// copies and derived works.
// 

#ifndef __OGLD_IF_H__
#define __OGLD_IF_H__


#if defined( WIN32 ) && !defined( __CYGWIN__ )
  // Eliminate warning 4786:
  //   "identifier was truncated to '255' characters in the debug information"
  #pragma warning (disable : 4786)
#endif

#include "OGLDPlatformGL.h"

// Determine which extry points we'll be getting from glext.h

#ifndef GL_VERSION_1_2
#define __OGLD_NEED_1_2
#endif
#ifndef GL_VERSION_1_3
#define __OGLD_NEED_1_3
#endif
#ifndef GL_VERSION_1_4
#define __OGLD_NEED_1_4
#endif
#ifndef GL_VERSION_1_5
#define __OGLD_NEED_1_5
#endif
#ifndef GL_VERSION_2_0
#define __OGLD_NEED_2_0
#endif

#ifndef __APPLE__
#include <GL/glext.h>
#endif
#include <stdlib.h>
#include <vector>
#include <string>


namespace ogld
{


typedef enum {
    VerUnknown,
    Ver10, Ver11, Ver12, Ver13, Ver14, Ver15,
    Ver20, VerExtended
} OpenGLVersion;

class OGLDif
{
public:
    static OGLDif* instance();

    OpenGLVersion getVersion();

    void* getProcAddress( const char* function );
    bool isExtensionSupported( const std::string& name, const GLubyte* extensions );

    int getDataPathSize() const;
    const std::string& getDataPath( int idx ) const;
    void addToDataPath( std::string path );
    void clearDataPath();

    void checkError();

protected:
    OGLDif();

    static OGLDif* _instance;

    void validate();
    bool _valid;

    void* getDLHandle();
    void* _dlHandle;

    OpenGLVersion _version;

    std::vector<std::string> _dataPath;
};

#ifdef _DEBUG

   // Development build: check for errors
#  define OGLDIF_CHECK_ERROR ogld::OGLDif::instance()->checkError()

#else

   // Release build: no-op
#  define OGLDIF_CHECK_ERROR

#endif


inline GLvoid*
bufferObjectPtr( unsigned int idx )
{
    return (GLvoid*)( ((char*)NULL) + idx );
}


} // namespace ogld



#ifndef OGLDIF_DECLARATION
#define OGLDIF_DECLARATION extern
#endif


#if defined( GL_VERSION_1_2 ) && defined( __OGLD_NEED_1_2 )
//
// Version 1.2 entry points
OGLDIF_DECLARATION PFNGLBLENDCOLORPROC glBlendColor;
OGLDIF_DECLARATION PFNGLBLENDEQUATIONPROC glBlendEquation;
OGLDIF_DECLARATION PFNGLDRAWRANGEELEMENTSPROC glDrawRangeElements;
OGLDIF_DECLARATION PFNGLCOLORTABLEPROC glColorTable;
OGLDIF_DECLARATION PFNGLCOLORTABLEPARAMETERFVPROC glColorTableParameterfv;
OGLDIF_DECLARATION PFNGLCOLORTABLEPARAMETERIVPROC glColorTableParameteriv;
OGLDIF_DECLARATION PFNGLCOPYCOLORTABLEPROC glCopyColorTable;
OGLDIF_DECLARATION PFNGLGETCOLORTABLEPROC glGetColorTable;
OGLDIF_DECLARATION PFNGLGETCOLORTABLEPARAMETERFVPROC glGetColorTableParameterfv;
OGLDIF_DECLARATION PFNGLGETCOLORTABLEPARAMETERIVPROC glGetColorTableParameteriv;
OGLDIF_DECLARATION PFNGLCOLORSUBTABLEPROC glColorSubTable;
OGLDIF_DECLARATION PFNGLCOPYCOLORSUBTABLEPROC glCopyColorSubTable;
OGLDIF_DECLARATION PFNGLCONVOLUTIONFILTER1DPROC glConvolutionFilter1D;
OGLDIF_DECLARATION PFNGLCONVOLUTIONFILTER2DPROC glConvolutionFilter2D;
OGLDIF_DECLARATION PFNGLCONVOLUTIONPARAMETERFPROC glConvolutionParameterf;
OGLDIF_DECLARATION PFNGLCONVOLUTIONPARAMETERFVPROC glConvolutionParameterfv;
OGLDIF_DECLARATION PFNGLCONVOLUTIONPARAMETERIPROC glConvolutionParameteri;
OGLDIF_DECLARATION PFNGLCONVOLUTIONPARAMETERIVPROC glConvolutionParameteriv;
OGLDIF_DECLARATION PFNGLCOPYCONVOLUTIONFILTER1DPROC glCopyConvolutionFilter1D;
OGLDIF_DECLARATION PFNGLCOPYCONVOLUTIONFILTER2DPROC glCopyConvolutionFilter2D;
OGLDIF_DECLARATION PFNGLGETCONVOLUTIONFILTERPROC glGetConvolutionFilter;
OGLDIF_DECLARATION PFNGLGETCONVOLUTIONPARAMETERFVPROC glGetConvolutionParameterfv;
OGLDIF_DECLARATION PFNGLGETCONVOLUTIONPARAMETERIVPROC glGetConvolutionParameteriv;
OGLDIF_DECLARATION PFNGLGETSEPARABLEFILTERPROC glGetSeparableFilter;
OGLDIF_DECLARATION PFNGLSEPARABLEFILTER2DPROC glSeparableFilter2D;
OGLDIF_DECLARATION PFNGLGETHISTOGRAMPROC glGetHistogram;
OGLDIF_DECLARATION PFNGLGETHISTOGRAMPARAMETERFVPROC glGetHistogramParameterfv;
OGLDIF_DECLARATION PFNGLGETHISTOGRAMPARAMETERIVPROC glGetHistogramParameteriv;
OGLDIF_DECLARATION PFNGLGETMINMAXPROC glGetMinmax;
OGLDIF_DECLARATION PFNGLGETMINMAXPARAMETERFVPROC glGetMinmaxParameterfv;
OGLDIF_DECLARATION PFNGLGETMINMAXPARAMETERIVPROC glGetMinmaxParameteriv;
OGLDIF_DECLARATION PFNGLHISTOGRAMPROC glHistogram;
OGLDIF_DECLARATION PFNGLMINMAXPROC glMinmax;
OGLDIF_DECLARATION PFNGLRESETHISTOGRAMPROC glResetHistogram;
OGLDIF_DECLARATION PFNGLRESETMINMAXPROC glResetMinmax;
OGLDIF_DECLARATION PFNGLTEXIMAGE3DPROC glTexImage3D;
OGLDIF_DECLARATION PFNGLTEXSUBIMAGE3DPROC glTexSubImage3D;
OGLDIF_DECLARATION PFNGLCOPYTEXSUBIMAGE3DPROC glCopyTexSubImage3D;
#endif


#if defined( GL_VERSION_1_3 ) && defined( __OGLD_NEED_1_3 )
//
// Version 1.3 entry points
OGLDIF_DECLARATION PFNGLACTIVETEXTUREPROC glActiveTexture;
OGLDIF_DECLARATION PFNGLCLIENTACTIVETEXTUREPROC glClientActiveTexture;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD1DPROC glMultiTexCoord1d;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD1DVPROC glMultiTexCoord1dv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD1FPROC glMultiTexCoord1f;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD1FVPROC glMultiTexCoord1fv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD1IPROC glMultiTexCoord1i;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD1IVPROC glMultiTexCoord1iv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD1SPROC glMultiTexCoord1s;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD1SVPROC glMultiTexCoord1sv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD2DPROC glMultiTexCoord2d;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD2DVPROC glMultiTexCoord2dv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD2FPROC glMultiTexCoord2f;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD2FVPROC glMultiTexCoord2fv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD2IPROC glMultiTexCoord2i;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD2IVPROC glMultiTexCoord2iv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD2SPROC glMultiTexCoord2s;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD2SVPROC glMultiTexCoord2sv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD3DPROC glMultiTexCoord3d;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD3DVPROC glMultiTexCoord3dv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD3FPROC glMultiTexCoord3f;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD3FVPROC glMultiTexCoord3fv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD3IPROC glMultiTexCoord3i;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD3IVPROC glMultiTexCoord3iv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD3SPROC glMultiTexCoord3s;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD3SVPROC glMultiTexCoord3sv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD4DPROC glMultiTexCoord4d;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD4DVPROC glMultiTexCoord4dv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD4FPROC glMultiTexCoord4f;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD4FVPROC glMultiTexCoord4fv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD4IPROC glMultiTexCoord4i;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD4IVPROC glMultiTexCoord4iv;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD4SPROC glMultiTexCoord4s;
OGLDIF_DECLARATION PFNGLMULTITEXCOORD4SVPROC glMultiTexCoord4sv;
OGLDIF_DECLARATION PFNGLLOADTRANSPOSEMATRIXFPROC glLoadTransposeMatrixf;
OGLDIF_DECLARATION PFNGLLOADTRANSPOSEMATRIXDPROC glLoadTransposeMatrixd;
OGLDIF_DECLARATION PFNGLMULTTRANSPOSEMATRIXFPROC glMultTransposeMatrixf;
OGLDIF_DECLARATION PFNGLMULTTRANSPOSEMATRIXDPROC glMultTransposeMatrixd;
OGLDIF_DECLARATION PFNGLSAMPLECOVERAGEPROC glSampleCoverage;
OGLDIF_DECLARATION PFNGLCOMPRESSEDTEXIMAGE3DPROC glCompressedTexImage3D;
OGLDIF_DECLARATION PFNGLCOMPRESSEDTEXIMAGE2DPROC glCompressedTexImage2D;
OGLDIF_DECLARATION PFNGLCOMPRESSEDTEXIMAGE1DPROC glCompressedTexImage1D;
OGLDIF_DECLARATION PFNGLCOMPRESSEDTEXSUBIMAGE3DPROC glCompressedTexSubImage3D;
OGLDIF_DECLARATION PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC glCompressedTexSubImage2D;
OGLDIF_DECLARATION PFNGLCOMPRESSEDTEXSUBIMAGE1DPROC glCompressedTexSubImage1D;
OGLDIF_DECLARATION PFNGLGETCOMPRESSEDTEXIMAGEPROC glGetCompressedTexImage;
#endif


#if defined( GL_VERSION_1_4 ) && defined( __OGLD_NEED_1_4 )
//
// Version 1.4 entry points
OGLDIF_DECLARATION PFNGLBLENDFUNCSEPARATEPROC glBlendFuncSeparate;
OGLDIF_DECLARATION PFNGLFOGCOORDFPROC glFogCoordf;
OGLDIF_DECLARATION PFNGLFOGCOORDFVPROC glFogCoordfv;
OGLDIF_DECLARATION PFNGLFOGCOORDDPROC glFogCoordd;
OGLDIF_DECLARATION PFNGLFOGCOORDDVPROC glFogCoorddv;
OGLDIF_DECLARATION PFNGLFOGCOORDPOINTERPROC glFogCoordPointer;
OGLDIF_DECLARATION PFNGLMULTIDRAWARRAYSPROC glMultiDrawArrays;
OGLDIF_DECLARATION PFNGLMULTIDRAWELEMENTSPROC glMultiDrawElements;
OGLDIF_DECLARATION PFNGLPOINTPARAMETERFPROC glPointParameterf;
OGLDIF_DECLARATION PFNGLPOINTPARAMETERFVPROC glPointParameterfv;
OGLDIF_DECLARATION PFNGLPOINTPARAMETERIPROC glPointParameteri;
OGLDIF_DECLARATION PFNGLPOINTPARAMETERIVPROC glPointParameteriv;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3BPROC glSecondaryColor3b;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3BVPROC glSecondaryColor3bv;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3DPROC glSecondaryColor3d;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3DVPROC glSecondaryColor3dv;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3FPROC glSecondaryColor3f;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3FVPROC glSecondaryColor3fv;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3IPROC glSecondaryColor3i;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3IVPROC glSecondaryColor3iv;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3SPROC glSecondaryColor3s;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3SVPROC glSecondaryColor3sv;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3UBPROC glSecondaryColor3ub;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3UBVPROC glSecondaryColor3ubv;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3UIPROC glSecondaryColor3ui;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3UIVPROC glSecondaryColor3uiv;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3USPROC glSecondaryColor3us;
OGLDIF_DECLARATION PFNGLSECONDARYCOLOR3USVPROC glSecondaryColor3usv;
OGLDIF_DECLARATION PFNGLSECONDARYCOLORPOINTERPROC glSecondaryColorPointer;
OGLDIF_DECLARATION PFNGLWINDOWPOS2DPROC glWindowPos2d;
OGLDIF_DECLARATION PFNGLWINDOWPOS2DVPROC glWindowPos2dv;
OGLDIF_DECLARATION PFNGLWINDOWPOS2FPROC glWindowPos2f;
OGLDIF_DECLARATION PFNGLWINDOWPOS2FVPROC glWindowPos2fv;
OGLDIF_DECLARATION PFNGLWINDOWPOS2IPROC glWindowPos2i;
OGLDIF_DECLARATION PFNGLWINDOWPOS2IVPROC glWindowPos2iv;
OGLDIF_DECLARATION PFNGLWINDOWPOS2SPROC glWindowPos2s;
OGLDIF_DECLARATION PFNGLWINDOWPOS2SVPROC glWindowPos2sv;
OGLDIF_DECLARATION PFNGLWINDOWPOS3DPROC glWindowPos3d;
OGLDIF_DECLARATION PFNGLWINDOWPOS3DVPROC glWindowPos3dv;
OGLDIF_DECLARATION PFNGLWINDOWPOS3FPROC glWindowPos3f;
OGLDIF_DECLARATION PFNGLWINDOWPOS3FVPROC glWindowPos3fv;
OGLDIF_DECLARATION PFNGLWINDOWPOS3IPROC glWindowPos3i;
OGLDIF_DECLARATION PFNGLWINDOWPOS3IVPROC glWindowPos3iv;
OGLDIF_DECLARATION PFNGLWINDOWPOS3SPROC glWindowPos3s;
OGLDIF_DECLARATION PFNGLWINDOWPOS3SVPROC glWindowPos3sv;
#endif


#if defined( GL_VERSION_1_5 ) && defined( __OGLD_NEED_1_5 )
//
// Version 1.5 entry points
OGLDIF_DECLARATION PFNGLGENQUERIESPROC glGenQueries;
OGLDIF_DECLARATION PFNGLDELETEQUERIESPROC glDeleteQueries;
OGLDIF_DECLARATION PFNGLISQUERYPROC glIsQuery;
OGLDIF_DECLARATION PFNGLBEGINQUERYPROC glBeginQuery;
OGLDIF_DECLARATION PFNGLENDQUERYPROC glEndQuery;
OGLDIF_DECLARATION PFNGLGETQUERYIVPROC glGetQueryiv;
OGLDIF_DECLARATION PFNGLGETQUERYOBJECTIVPROC glGetQueryObjectiv;
OGLDIF_DECLARATION PFNGLGETQUERYOBJECTUIVPROC glGetQueryObjectuiv;
OGLDIF_DECLARATION PFNGLBINDBUFFERPROC glBindBuffer;
OGLDIF_DECLARATION PFNGLDELETEBUFFERSPROC glDeleteBuffers;
OGLDIF_DECLARATION PFNGLGENBUFFERSPROC glGenBuffers;
OGLDIF_DECLARATION PFNGLISBUFFERPROC glIsBuffer;
OGLDIF_DECLARATION PFNGLBUFFERDATAPROC glBufferData;
OGLDIF_DECLARATION PFNGLBUFFERSUBDATAPROC glBufferSubData;
OGLDIF_DECLARATION PFNGLGETBUFFERSUBDATAPROC glGetBufferSubData;
OGLDIF_DECLARATION PFNGLMAPBUFFERPROC glMapBuffer;
OGLDIF_DECLARATION PFNGLUNMAPBUFFERPROC glUnmapBuffer;
OGLDIF_DECLARATION PFNGLGETBUFFERPARAMETERIVPROC glGetBufferParameteriv;
OGLDIF_DECLARATION PFNGLGETBUFFERPOINTERVPROC glGetBufferPointerv;
#endif


#if defined( GL_VERSION_2_0 ) && defined( __OGLD_NEED_2_0 )
//
// Version 2.0 entry points
OGLDIF_DECLARATION PFNGLBLENDEQUATIONSEPARATEPROC glBlendEquationSeparate;
OGLDIF_DECLARATION PFNGLDRAWBUFFERSPROC glDrawBuffers;
OGLDIF_DECLARATION PFNGLSTENCILOPSEPARATEPROC glStencilOpSeparate;
OGLDIF_DECLARATION PFNGLSTENCILFUNCSEPARATEPROC glStencilFuncSeparate;
OGLDIF_DECLARATION PFNGLSTENCILMASKSEPARATEPROC glStencilMaskSeparate;
OGLDIF_DECLARATION PFNGLATTACHSHADERPROC glAttachShader;
OGLDIF_DECLARATION PFNGLBINDATTRIBLOCATIONPROC glBindAttribLocation;
OGLDIF_DECLARATION PFNGLCOMPILESHADERPROC glCompileShader;
OGLDIF_DECLARATION PFNGLCREATEPROGRAMPROC glCreateProgram;
OGLDIF_DECLARATION PFNGLCREATESHADERPROC glCreateShader;
OGLDIF_DECLARATION PFNGLDELETEPROGRAMPROC glDeleteProgram;
OGLDIF_DECLARATION PFNGLDELETESHADERPROC glDeleteShader;
OGLDIF_DECLARATION PFNGLDETACHSHADERPROC glDetachShader;
OGLDIF_DECLARATION PFNGLDISABLEVERTEXATTRIBARRAYPROC glDisableVertexAttribArray;
OGLDIF_DECLARATION PFNGLENABLEVERTEXATTRIBARRAYPROC glEnableVertexAttribArray;
OGLDIF_DECLARATION PFNGLGETACTIVEATTRIBPROC glGetActiveAttrib;
OGLDIF_DECLARATION PFNGLGETACTIVEUNIFORMPROC glGetActiveUniform;
OGLDIF_DECLARATION PFNGLGETATTACHEDSHADERSPROC glGetAttachedShaders;
OGLDIF_DECLARATION PFNGLGETATTRIBLOCATIONPROC glGetAttribLocation;
OGLDIF_DECLARATION PFNGLGETPROGRAMIVPROC glGetProgramiv;
OGLDIF_DECLARATION PFNGLGETPROGRAMINFOLOGPROC glGetProgramInfoLog;
OGLDIF_DECLARATION PFNGLGETSHADERIVPROC glGetShaderiv;
OGLDIF_DECLARATION PFNGLGETSHADERINFOLOGPROC glGetShaderInfoLog;
OGLDIF_DECLARATION PFNGLGETSHADERSOURCEPROC glGetShaderSource;
OGLDIF_DECLARATION PFNGLGETUNIFORMLOCATIONPROC glGetUniformLocation;
OGLDIF_DECLARATION PFNGLGETUNIFORMFVPROC glGetUniformfv;
OGLDIF_DECLARATION PFNGLGETUNIFORMIVPROC glGetUniformiv;
OGLDIF_DECLARATION PFNGLGETVERTEXATTRIBDVPROC glGetVertexAttribdv;
OGLDIF_DECLARATION PFNGLGETVERTEXATTRIBFVPROC glGetVertexAttribfv;
OGLDIF_DECLARATION PFNGLGETVERTEXATTRIBIVPROC glGetVertexAttribiv;
OGLDIF_DECLARATION PFNGLGETVERTEXATTRIBPOINTERVPROC glGetVertexAttribPointerv;
OGLDIF_DECLARATION PFNGLISPROGRAMPROC glIsProgram;
OGLDIF_DECLARATION PFNGLISSHADERPROC glIsShader;
OGLDIF_DECLARATION PFNGLLINKPROGRAMPROC glLinkProgram;
OGLDIF_DECLARATION PFNGLSHADERSOURCEPROC glShaderSource;
OGLDIF_DECLARATION PFNGLUSEPROGRAMPROC glUseProgram;
OGLDIF_DECLARATION PFNGLUNIFORM1FPROC glUniform1f;
OGLDIF_DECLARATION PFNGLUNIFORM2FPROC glUniform2f;
OGLDIF_DECLARATION PFNGLUNIFORM3FPROC glUniform3f;
OGLDIF_DECLARATION PFNGLUNIFORM4FPROC glUniform4f;
OGLDIF_DECLARATION PFNGLUNIFORM1IPROC glUniform1i;
OGLDIF_DECLARATION PFNGLUNIFORM2IPROC glUniform2i;
OGLDIF_DECLARATION PFNGLUNIFORM3IPROC glUniform3i;
OGLDIF_DECLARATION PFNGLUNIFORM4IPROC glUniform4i;
OGLDIF_DECLARATION PFNGLUNIFORM1FVPROC glUniform1fv;
OGLDIF_DECLARATION PFNGLUNIFORM2FVPROC glUniform2fv;
OGLDIF_DECLARATION PFNGLUNIFORM3FVPROC glUniform3fv;
OGLDIF_DECLARATION PFNGLUNIFORM4FVPROC glUniform4fv;
OGLDIF_DECLARATION PFNGLUNIFORM1IVPROC glUniform1iv;
OGLDIF_DECLARATION PFNGLUNIFORM2IVPROC glUniform2iv;
OGLDIF_DECLARATION PFNGLUNIFORM3IVPROC glUniform3iv;
OGLDIF_DECLARATION PFNGLUNIFORM4IVPROC glUniform4iv;
OGLDIF_DECLARATION PFNGLUNIFORMMATRIX2FVPROC glUniformMatrix2fv;
OGLDIF_DECLARATION PFNGLUNIFORMMATRIX3FVPROC glUniformMatrix3fv;
OGLDIF_DECLARATION PFNGLUNIFORMMATRIX4FVPROC glUniformMatrix4fv;
OGLDIF_DECLARATION PFNGLVALIDATEPROGRAMPROC glValidateProgram;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB1DPROC glVertexAttrib1d;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB1DVPROC glVertexAttrib1dv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB1FPROC glVertexAttrib1f;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB1FVPROC glVertexAttrib1fv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB1SPROC glVertexAttrib1s;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB1SVPROC glVertexAttrib1sv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB2DPROC glVertexAttrib2d;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB2DVPROC glVertexAttrib2dv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB2FPROC glVertexAttrib2f;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB2FVPROC glVertexAttrib2fv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB2SPROC glVertexAttrib2s;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB2SVPROC glVertexAttrib2sv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB3DPROC glVertexAttrib3d;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB3DVPROC glVertexAttrib3dv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB3FPROC glVertexAttrib3f;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB3FVPROC glVertexAttrib3fv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB3SPROC glVertexAttrib3s;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB3SVPROC glVertexAttrib3sv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4NBVPROC glVertexAttrib4Nbv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4NIVPROC glVertexAttrib4Niv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4NSVPROC glVertexAttrib4Nsv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4NUBPROC glVertexAttrib4Nub;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4NUBVPROC glVertexAttrib4Nubv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4NUIVPROC glVertexAttrib4Nuiv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4NUSVPROC glVertexAttrib4Nusv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4BVPROC glVertexAttrib4bv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4DPROC glVertexAttrib4d;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4DVPROC glVertexAttrib4dv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4FPROC glVertexAttrib4f;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4FVPROC glVertexAttrib4fv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4IVPROC glVertexAttrib4iv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4SPROC glVertexAttrib4s;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4SVPROC glVertexAttrib4sv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4UBVPROC glVertexAttrib4ubv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4UIVPROC glVertexAttrib4uiv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIB4USVPROC glVertexAttrib4usv;
OGLDIF_DECLARATION PFNGLVERTEXATTRIBPOINTERPROC glVertexAttribPointer;
#endif


// #ifndef __OGLD_IF_H__
#endif
